/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package LN;

import Objects.City;
import Objects.Country;
import Objects.Municipality;
import Objects.Parish;
import Objects.State;
import java.util.List;
/**
 *
 * @author ARMGARCES
 */
public class LnLugares {
    /***************************************************************************/
    /******************************** COUNTRY **********************************/
    /***************************************************************************/    
    /**
     * 
     * @return 
     */
    public Country[] load_Country() {
//        try{
            List<Wsdl.Country> country = WSClient.WSClientLugares.loadCountry();
                    //.load_Country();      
            return (Country[]) country.toArray();
//        }catch(SQLException e){
//            Gui.getInstance().ventanaError("Error Cargando Usuarios: \n"+e.getMessage()); 
//        }
//        return null;
    }    
    /***************************************************************************/
    /********************************* STATE ***********************************/
    /***************************************************************************/    
    /**
     * 
     * @return 
     */
    public State[] load_State() {
//        try{
            List<Wsdl.State> state = WSClient.WSClientLugares.loadState();
            return (State[]) state.toArray();
//        }catch(SQLException e){
//            Gui.getInstance().ventanaError("Error Cargando Usuarios: \n"+e.getMessage()); 
//        }
//        return null;
    }    
    /**
     * 
     * @param find
     * @return 
     */
    public State[] find_State(String find) {
//        try{
            List<Wsdl.State> state = WSClient.WSClientLugares.findState(find);
            return (State[]) state.toArray();
//        }catch(SQLException e){
//            Gui.getInstance().ventanaError("Error Cargando Usuarios: \n"+e.getMessage()); 
//        }
//        return null;
    }    
    /***************************************************************************/
    /********************************** CITY ***********************************/
    /***************************************************************************/    
    /**
     * 
     * @return 
     */
    public City[] load_City() {
//        try{
            List<Wsdl.City> city = WSClient.WSClientLugares.loadCity();      
            return (City[]) city.toArray();
//        }catch(SQLException e){
//            Gui.getInstance().ventanaError("Error Cargando Usuarios: \n"+e.getMessage()); 
//        }
//        return null;
    }    
    /**
     * 
     * @param find
     * @return 
     */
    public City[] find_City(String find) {
//        try{
            List<Wsdl.City> city = WSClient.WSClientLugares.findCity(find);      
            return (City[]) city.toArray();
//        }catch(SQLException e){
//            Gui.getInstance().ventanaError("Error Cargando Usuarios: \n"+e.getMessage()); 
//        }
//        return null;
    }    
    /***************************************************************************/
    /****************************** MUNICIPALITY *******************************/
    /***************************************************************************/    
    /**
     * 
     * @return 
     */
    public Municipality[] load_Municipality() {
//        try{
            List<Wsdl.Municipality> municipality = WSClient.WSClientLugares.loadMunicipality();      
            return (Municipality[]) municipality.toArray();
//        }catch(SQLException e){
//            Gui.getInstance().ventanaError("Error Cargando Usuarios: \n"+e.getMessage()); 
//        }
//        return null;
    }    
    /**
     * 
     * @param find
     * @return 
     */
    public Municipality[] find_Municipality(String find) {
//        try{
            List<Wsdl.Municipality> municipality = WSClient.WSClientLugares.findMunicipality(find);      
            return (Municipality[]) municipality.toArray();
//        }catch(SQLException e){
//            Gui.getInstance().ventanaError("Error Cargando Usuarios: \n"+e.getMessage()); 
//        }
//        return null;
    }    
    /***************************************************************************/
    /********************************* PARISH **********************************/
    /***************************************************************************/    
    /**
     * 
     * @return 
     */
    public Parish[] load_Parish() {
//        try{
            List<Wsdl.Parish> parish = WSClient.WSClientLugares.loadParish();      
            return (Parish[]) parish.toArray();
//        }catch(SQLException e){
//            Gui.getInstance().ventanaError("Error Cargando Usuarios: \n"+e.getMessage()); 
//        }
//        return null;
    }    
    /**
     * 
     * @param findM
     * @param findS
     * @return 
     */
    public Parish[] find_Parish(String findM, String findS) {
//        try{
            List<Wsdl.Parish> parish = WSClient.WSClientLugares.findParish(findM, findS);   
            return (Parish[]) parish.toArray();
//        }catch(SQLException e){
//            Gui.getInstance().ventanaError("Error Cargando Usuarios: \n"+e.getMessage()); 
//        }
//        return null;
    }    
}
